//
//  CXTestViewController.swift
//  XinaWeibo
//
//  Created by chenxuan on 2017/4/5.
//  Copyright © 2017年 chenxuan. All rights reserved.
//

import UIKit

class CXTestViewController: CXBaseViewController {

    override func viewDidLoad() {
        super.viewDidLoad()
        setupNewVC()
        // Do any additional setup after loading the view.
    }

    /// 继续 PUSH 一个新的控制器
    @objc fileprivate func showNext() {
        
        let vc = CXTestViewController()
        
        navigationController?.pushViewController(vc, animated: true)
    }
}

extension CXTestViewController {
    
    /// 重写父类方法
    func setupNewVC() {
        
        
        // 设置右侧的控制器
        navItem.rightBarButtonItem = UIBarButtonItem(title: "下一个", target: self, action: #selector(showNext))
    }
}
